home *** CD-ROM | disk | FTP | other *** search
/ Fritz: All Fritz / All Fritz.zip / All Fritz / FILES / PROGNG_C / CUG187.LZH / SAVEDTA.C < prev    next >
C/C++ Source or Header  |  1986-02-21  |  949b  |  27 lines

  1. /*@*****************************************************/
  2. /*@                                                    */
  3. /*@ savedta -  save the current DOS DTA for later.     */
  4. /*@                                                    */
  5. /*@   Usage:     savedta();                            */
  6. /*@                                                    */
  7. /*@       returns zero.                                */
  8. /*@                                                    */
  9. /*@       NOTE: restdta() restores it.                 */
  10. /*@                                                    */
  11. /*@*****************************************************/
  12.  
  13.  
  14. extern unsigned _rax, _rbx, _rcx, _rdx, _rsi, _rdi, _res, _rds;
  15. extern char _carryf, _zerof;
  16.  
  17. int dtads, dtadx;
  18.  
  19. savdta()
  20. {
  21.     _rax = 0x2f00;            /* get dta func */
  22.     _doint(0x21);            /* call DOS */
  23.     dtads = _res;            /* segment for dta */
  24.     dtadx = _rbx;            /* offset for dta */
  25.     return 0;
  26. }
  27.